<!DOCTYPE html>
<html lang="en">
<head>
    <meta name="viewport" content="width=device-width,user-scalable=0"/>
    <meta charset="UTF-8">
    <title>BD健身</title>
    <script src="__api__/js/fontSize.js"></script>
    <link rel="stylesheet" href="__api__/css/bootstrap.min.css">
    <link rel="stylesheet" href="__api__/css/reset.css">
    <link rel="stylesheet" href="__api__/css/my_main.css">
    <link rel="stylesheet" href="__api__/css/dropload.css">
    <style>
        body{
            background-color: #ebebeb;
        }
    </style>
</head>
<body ontouchstart=""  id="container">
<!--<header class="tabHead">-->
    <!--<span class="active">我的收藏</span>-->
    <!--<span>我的评价</span>-->
    <!--<div class="sanjiao"></div>-->
<!--</header>-->
<div class="my-coll">
    <header class="tabHead">
        <span class="active">我的收藏</span>
        <span>我的评价</span>
        <b class="border"></b>
    </header>
</div>

<div class="khfxWarp">
    <section class="khfxPane" style="display:block">
    {volist name="data.favorite" id="item"}
   <input type="hidden" value="{$item.id}" id="fa">
        <div class="container">
            <div class="collect" id="coll1">

                <div class="row">
                   <div class="col-xs-4 col-md-4">
                        <div class="collect_img">
                            <img src="__api__/{$item.veninfo['img']}">
                        </div>
                   </div>
                   <div class="col-xs-6 col-md-6">
                       <div class="collect_text">
                        <a href="{:url('api/Venue/VenueDetails')}?id={$item.veninfo['id']}">
                          <h3>{$item.veninfo['designation']}</h3>
                          <p>{$item.veninfo['address']}</p>
                          </a>
                          <div class="coll_eavl">
                              <div class="coll_phone" data-toggle="modal" data-target="#myModal">
                                  <img src="__api__/images/phone.png">
                              </div>

                              <a href="{:url('api/Venue/Evation')}?id={$item.veninfo['id']}">评价<span>{$item.veninfo['eva']}</span></a>
                          </div>
                       </div>
                   </div>
                   <div class="col-xs-2 col-md-2">
                      <div class="del_img">
                         <img src="__api__/images/del.png">
                      </div>
                   </div>
             </div>
            </div>

        </div>
        <div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
            <div class="modal-dialog" role="document">
                <div class="modal-content">
                    <div class="modal-header">
                        <h4 class="modal-title" id="myModalLabel">确认拨打{$item.veninfo['telphone']}</h4>
                    </div>
                    <div class="modal-body">
                        联系店长
                    </div>
                    <div class="modal-footer">
                        <a href="javascript:" class="btn btn-default" data-dismiss="modal">取消</a>
                        <a href="javascript:" class="btn btn-primary">确定</a>
                    </div>
                </div>
            </div>
        </div>
       
{/volist}
    </section>

    <section class="khfxPane">
        <div class="my_eval">
            <div class="container">
            {volist name="data.evat" id="eva"}
                <div class="eval_cont">
                    <div class="eval-date">
                        <div></div>
                        <span>{$eva.jiben['evaluation_time']|date="Y-m-d",###}</span>
                    </div>
                    <img alt="" src="__api__/images/star{$eva.jiben['grade']}.png">
                    <p class="eval_text">{$eva.jiben['content']}</p>
                    <a href="javascript:">
                    <div class="shop">

                            <div class="row">
                                <div class="col-xs-4">
                                    <div class="shop_img">
                                        <img src="__api__/{$eva.veinfo['img']}">
                                    </div>
                                </div>
                                <div class="col-xs-8">
                                    <div class="shop_text">
                                        <h3>[{$eva.veinfo['designation']}]{$eva.veninfo['address']}</h3>
                                        <p>{$eva.jiben['appoint_time']}场地位{$eva.count}个</p>
                                    </div>
                                </div>

                            </div>


                    </div>
                    </a>
                    <div class="service">
                        <p></p>
                    </div>
                </div>
                {/volist}
            </div>
        </div>
    </section>

</div>

<script src="__api__/js/jquery-3.2.1.min.js"></script>
<script src="__api__/js/bootstrap.min.js"></script>
<script src="__api__/js/khData.js"></script>
<script src="__assets__/layui.js"></script>
<script type="text/javascript">
var layer;
layui.use('layer', function(){
	   layer = layui.layer;
	  
	  //layer.msg('hello');
	}); 
    $(".del_img").click(function(){
        $(this).parent().parent().parent().fadeOut(200, function(){
            $(this).remove();
           
            var url="{:url('api/favorite/deletes')}";
            var id=$('#fa').val();
            var data={id:id};
            $.get(url,data,function(res){
            	var obj=eval('('+res+')');
            	var staus=obj.status;
            	var info=obj.info;
            	if(status==1){
            		layer.msg(info,{icon:6});
            	}else{
            		layer.msg(info,{icon:6});
            	}
            })
        });
    });
</script>

</body>
</html>